require 'Connection.rb'
require 'ConnectionDao.rb'
require 'BookingDao.rb'
require 'VersionDao.rb'
require 'VersionInterpreter.rb'
require 'FlightsInterpreter.rb'
require 'AirportsInterpreter.rb'
require 'BookingInterpreter.rb'

#
# CPL Assignment 2
# Tim Caljé, Jeroen De Raedt & Jorick Van Aken
#
class InterpreterFactory
  
  def initialize
    @connection = Connection.new
    @connectionDao = ConnectionDao.new(@connection)
    @bookingDao = BookingDao.new(@connection)
    @versionDao = VersionDao.new(@connection)
    
    @connectionDao.bookingDao(@bookingDao)
  end
  
  def getFlightsInterpreter
    FlightsInterpreter.new(@connectionDao)
  end
  
  def getAirportsInterpreter
    AirportsInterpreter.new(@connectionDao)
  end
  
  def getVersionInterpreter
    VersionInterpreter.new(@versionDao)
  end
  
  def getBookingInterpreter
    BookingInterpreter.new(@bookingDao)
  end
  
end